package com.xujl.utilslibrary.paramcorrect;

import android.util.Log;

import com.xujl.utilslibrary.data.TypeUtils;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;

/**
 * Created by xujl on 2018/1/19.
 */

class Test {
    public static void main (String[] arg) {
        final Bean bean = new Bean();
        List<Bean> list = new ArrayList<>();
        list.add(new Bean());
        list.add(new Bean());
        list.add(new Bean());
        final ParamCorrectUtils utils = new ParamCorrectUtils();
        utils.addValue(TypeUtils.TYPE_STRING,"name");
        try {
            utils.correctAll(bean);
        } catch (IllegalAccessException e) {
            e.printStackTrace();
        }
        System.err.println("修正完毕000000000000");
    }

    public static class Bean {
        @Correct
//        @CorrectValue(StringValue = "name")
        public String name;
        @Correct
        public List<Bean2> list = Arrays.asList(new Bean2(),new Bean2(),new Bean2());
    }
    public static class Bean2{
        @Correct
//        @CorrectValue(StringValue = "pass")
        public String pass;
    }
}
